package pl.edu.agh.inpema.core.model;

import pl.edu.agh.inpema.core.components.ReceiverUtil;

public interface Receiver {
	
	public static final String FIELD_IP = "ip";
	public static final String FIELD_DATE = "date";
	public static final String FIELD_TEXT = "text";
	
	/**
	 * starts receiver
	 */
	public void startGathering(); 
	
	/**
	 * stops receiver
	 * @return true if error(s) occurred, false if operation was success
	 */
	public boolean stopGathering();

	/**
	 * check if receiver is running
	 * @return true if receiver is running, false otherwise
	 */
	public boolean isGatheringRunning();
	
	/**
	 * sets the receiver util
	 * @param analyzerUtil receiver util
	 */
	public void setReceiverUtil(ReceiverUtil receiverUtil);
	
	/**
	 * get receiver util
	 * @return receiver util
	 */
	public ReceiverUtil getReceiverUtil();
	
	/**
	 * get array of field types, that this receiver serve 
	 * @return array of field types, that this receiver serve
	 */
	public String[] getMessageFieldTypes();
}
